home *** CD-ROM | disk | FTP | other *** search
- Path: god.bel.alcatel.be!nlev00!barnhoorn
- From: barnhoorn@nlev00 ()
- Newsgroups: comp.sys.amiga.programmer
- Subject: Re: File sizes
- Date: 26 Feb 1996 07:50:57 GMT
- Organization: Alcatel Bell
- Distribution: world
- Message-ID: <4grop1$puv@btmpjg.god.bel.alcatel.be>
- References: <4gd9pu$cpr@mn5.swip.net> <WXQ7y*5+f@yaps.rhein.de> <4gjs20$i68@btmpjg.god.bel.alcatel.be> <Dn81zD.H5M.0.-s@cs.vu.nl>
- Reply-To: barnhoorn@nlev00 ()
- NNTP-Posting-Host: 138.203.178.61
- X-Newsreader: mxrn 6.18-10
-
-
- In article <Dn81zD.H5M.0.-s@cs.vu.nl>, irmen@cs.vu.nl (Irmen de Jong) writes:
- |> On 23 Feb 1996 07:57:52 GMT barnhoorn@nlev00 (barnhoorn@nlev00) wrote:
- |> : |> > What's the best way of finding out the size of a file? Do I have to use
- |> : |> > Examine()
- |> : ..or do it in ANSI-C, by opening the file, seeking to the end of it
- |> : and getting the number of bytes returned from fseek().
- |> Aaaargh why does nobody use fstat()? Seeking to the end of a many-megabyte-file
- |> can take ages, especially on floppy. fstat() (and dos.library/Examine()) are
- |> instantaneous, AFAIK.
-
- I admit that fseek() might take a long time to return. But I think
- fseek() will return the real filesize, also on XPK-devices, because
- it has to be unpacked.
- Is fstat() a function that decrunches the file also?
-
- ---------------------------------------------------------------------------
- Jaco Barnhoorn barnie@xs4all.nl
- Software Test Engineer barnhoorn%nlev00@btmv56.se.bel.alcatel.be
- Alcatel Telecom Systems
- Rijswijk, The Netherlands
- ---------------------------------------------------------------------------
-